<%@ page contentType="text/html; charset=iso-8859-1" language="java" import="java.sql.*" errorPage="" %>
<%@page import="java.math.BigInteger"%>
<%@page import="java.security.MessageDigest"%>
<%@page import="java.security.NoSuchAlgorithmException"%>

<%
	String pass = "ebskey" + "|" +
		      (String)request.getParameter("account_id") + "|" + 
		      (String)request.getParameter("amount") + "|" + 
		      (String)request.getParameter("reference_no") + "|" +
		      (String)request.getParameter("return_url") + "|" + 
		      (String)request.getParameter("mode");
	MessageDigest m = MessageDigest.getInstance("MD5");
	byte[] data = pass.getBytes();
	m.update(data,0,data.length);
	BigInteger i = new BigInteger(1,m.digest());
	String secure_hash = String.format("%1$032X", i);
%>

<script>
	setTimeout('document.frmTransaction.submit()',0);
</script>

<form  method="post" action="https://secure.ebs.in/pg/ma/sale/pay" name="frmTransaction" id="frmTransaction">
	<input name="account_id" type="hidden" value="<%=request.getParameter("account_id")%>">
	<input name="return_url" type="hidden" size="60" value="<%=request.getParameter("return_url")%>" />
	<input name="mode" type="hidden" size="60" value="<%=request.getParameter("mode")%>" />
	<input name="reference_no" type="hidden" value="<%=request.getParameter("reference_no")%>" />
	<input name="amount" type="hidden" value="<%=request.getParameter("amount")%>"/>
	<input name="description" type="hidden" value="<%=request.getParameter("description")%>" /> 
	
	<input name="name" type="hidden" maxlength="255" value="vinoth" />
	<input name="address" type="hidden" maxlength="255" value="Test" />
	<input name="city" type="hidden" maxlength="255" value="Chennai" />
	<input name="state" type="hidden" maxlength="255" value="Tamil Nadu" />
	<input name="postal_code" type="hidden" maxlength="255" value="600030" />
	<input name="country" type="hidden" maxlength="255" value="ind" />
	<input name="phone" type="hidden" maxlength="255" value="9942386997" />
	<input name="email" type="hidden" maxlength="255" value="sl.vinoth@gmail.com" />
	<input name="secure_hash" type="hidden" size="60" value="<%=secure_hash%>" />
	<input name="submitted" type="hidden" value="Submit" type="submit" />
</form>